package dfs;

import java.util.ArrayList;
import java.util.Scanner;

import static java.lang.System.exit;
import static java.lang.System.setOut;

public class _02部分和 {
    static int kk = 0;

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] a = new int[n];
        for (int i = 0; i < n; i++) {
            a[i] = sc.nextInt();
        }
        int k = sc.nextInt();
        kk = k;
        dfs(a, k, 0, new ArrayList<Integer>());
    }

    private static void dfs(int[] a, int k, int cur, ArrayList<Integer> ints) {
        if (k == 0) {
            System.out.print("YES(" + kk + " = ");
            int size = ints.size();
            for (int i = 0; i < size; i++) {
                System.out.print(ints.get(i) + (i == size - 1 ? "" : " + "));
            }
            System.out.println(")");;
            exit(0);
        }
        if (k < 0 || cur == a.length) return;
        dfs(a, k, cur + 1, ints); //不选当前元素，往下走
        ints.add(a[cur]);
        int index = ints.size() - 1;
        dfs(a, k - a[cur], cur + 1, ints); //选了当前元素，k加上后变小
        ints.remove(index);//回溯
    }
}
